/**
 * File: ProjectConstants.java
 * Author: Ben Stutsky
 * Team: Bob-omb Squad
 * Date: 4/18/11
 * Email: stutsky1@umbc.edu
 */
package clientApp;

/**
 * The Interface ProjectConstants.
 */
public abstract class ProjectConstants {

	/** The FALL Constant. */
	public static final int FALL = -82651;
	
	/** The SPRING Constant. */
	public static final int SPRING = -82649;
	
	/** The WINTER Constant. */
	public static final int WINTER = -82648;
	
	/** The SUMMER Constant. */
	public static final int SUMMER = -82650;
	
	/** The CMSC Constant. */
	public static final int CMSC = -475629;
	
	/** The IS Constant. */
	public static final int IS = -475630;
	
	/** The CSIS Constant. */
	public static final int CSIS = -475631;
	
	/** The IS_WITH_CS_MINOR Constant. */
	public static final int IS_WITH_CS_MINOR = -475632;
	
	/** The UNDECIDED constant*/
	public static final int UNDECIDED = -475633;
	
	/** The NO_GRADE Constant */
	public static final char NO_GRADE = 'I';
	
	public static String getSeasonString(int seasonInt)
	{
		switch (seasonInt)
		{
			case SUMMER:
				return "Summer";
			case WINTER:
				return "Winter";
			case FALL:
				return "Fall";
			case SPRING:
				return "Spring";
			default: 
				return "Season Not Found";
		}
	}
	
	public static int getSeasonInt(String seasonStr)
	{
		if(seasonStr.toLowerCase().compareTo("fall") == 0)
		{
			return FALL;
		}
		else if(seasonStr.toLowerCase().compareTo("spring") == 0)
		{
			return SPRING;
		}
		else if(seasonStr.toLowerCase().compareTo("summer") == 0)
		{
			return SUMMER;
		}
		else if(seasonStr.toLowerCase().compareTo("winter") == 0)
		{
			return WINTER;
		}
		else
		{
			return -1;
		}
	}

	public static String getDegreeString(int degreeInt)
	{
		switch (degreeInt)
		{
			case CMSC:
				return "Computer Science Major";
			case IS:
				return "Information Systems Major";
			case CSIS:
				return "Computer Science and Information Systems";
			case IS_WITH_CS_MINOR:
				return "Information Systems with Computer Science Minor";
			case UNDECIDED:
				return "Undecided";
			default:
				return "Degree Name Not Found";
		}
	}
	
	public static int getDegreeInt(String degreeStr)
	{
		if(degreeStr.toLowerCase().compareTo("computer science major") == 0)
		{
			return CMSC;
		}
		else if(degreeStr.toLowerCase().compareTo("information systems major") == 0)
		{
			return IS;
		}
		else if(degreeStr.toLowerCase().compareTo("computer science and information systems") == 0)
		{
			return CSIS;
		}
		else if(degreeStr.toLowerCase().compareTo("information systems with computer science minor") == 0)
		{
			return IS_WITH_CS_MINOR;
		}
		else if(degreeStr.toLowerCase().compareTo("undecided") == 0)
		{
			return UNDECIDED;
		}
		else
		{
			return -1;
		}
	}

}
